package com.uzai.common.enums.activity;

import java.util.Objects;

/**
 * @author mingyang.chen create in 2023/7/28 15:42
 */
public enum IndexActivityScenesEnum {

    hdk_good_informant(1, "好单库-好单线报"),

    hdk_hundred_billions_allowance(2, "好单库-百亿补贴"),

    hdk_low_price_shipping(3, "好单库-低价包邮"),

    most_one(4, "优惠头条"),

    material_selection(5, "物料精选"),

    official_activity(6, "官方活动"),

    you_zai_selection(7, "悠哉精选"),

    vph_official(8, "唯品会官方活动"),

    vph_outside(9, "唯品会特卖活动-站外"),

    hdk_heavenly_benefits(10, "好单库-天降福利"),

    jd_jf(11, "京东-京粉"),

    pdd_official(12, "拼多多-官方"),

    tb_same_goods(13, "同款宝贝"),

    tb_like_goods(14, "相似宝贝"),

    tb_rank_goods(15, "相关榜单"),

    jd_recommended_for_you(16, "为你推荐"),

    jd_recommended_for_today(17, "今日推荐"),

    pdd_choice_goods(18, "精选爆品"),

    pdd_brand_goods(19, "品牌爆品"),

    vph_special_price_discount(20, "特价优惠"),

    vph_quick_get(21, "唯品快抢"),

    vph_big_brand_discount(22, "大牌优惠"),

    jd_outside(24, "官方活动"),

    pdd_you_zai_selection(25, "拼多多-悠哉精选"),

    ;

    private final Integer code;

    private final String desc;


    IndexActivityScenesEnum(Integer code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    /**
     * Gets by code.
     *
     * @param code the code
     * @return the by code
     */
    public static IndexActivityScenesEnum getByCode(Integer code) {
        for (IndexActivityScenesEnum value : IndexActivityScenesEnum.values()) {
            if (Objects.equals(value.code, code)) {
                return value;
            }
        }
        return null;
    }

    /**
     * Gets code.
     *
     * @return the code
     */
    public Integer getCode() {
        return code;
    }

    /**
     * Gets desc.
     *
     * @return the desc
     */
    public String getDesc() {
        return desc;
    }
}
